import java.util.Arrays;
public class Test6 {
	public static void main(String[] args) {
		int[] a = {0,36,66,5,13,28,1};                 //初始化a数组
		Arrays.sort(a);                             //对a数组进行排序
		System.out.println("a数组的元素是：");
		for (int i = 0; i < a.length; i++) {               //对数组中的元素进行遍历输出
			System.out.print(a[i]+" ");
		}
		int increase = 3;                            //容量增加量
		int[] b = new int[a.length+increase];            //初始化b数组
		System.arraycopy(a, 0, b, 0, a.length);          //将a数组拷贝到b数组
		int num = 100;                             //定义整型变量并赋初值100
		for (int i = a.length; i < b.length; i++) {          //对b数组的剩余元素赋值
			b[i] = num;
			num = num+1;
		}
		System.out.println();
		Arrays.sort(b);                              //对b数组进行排序
		System.out.println("扩容后b数组的元素是：");
		for (int i = 0; i < b.length; i++) {
			System.out.print(b[i]+" ");
		}
	}
}